package com.ocl.www.service;

import com.ocl.www.domain.Comment;
import com.ocl.www.mapper.CommentMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CommentService {

    @Autowired
    private CommentMapper commentMapper;

    public List<Comment> selectComments(Comment comm,int commCount) throws  Exception{
        return commentMapper.selectComments(comm,commCount);
    }

    public int insertComment(Comment comm) throws  Exception{
        int c =0 ;
        c = commentMapper.insertComment(comm);
        return c;
    }

}
